package com.txts.road.app.event.model.dto;

import java.io.Serial;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import java.time.LocalDateTime;
import com.fasterxml.jackson.annotation.JsonFormat;
import jakarta.validation.constraints.*;

/**
 * 赛事活动表单对象
 *
 * @author baoyr
 * @since 2025-07-17 10:47
 */
@Getter
@Setter
@Schema(description = "赛事活动表单对象")
public class EventDTO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "赛事ID")
    @NotNull(message = "赛事ID不能为空")
    private Long id;

    @Schema(description = "赛事名称")
    @NotBlank(message = "赛事名称不能为空")
    @Size(max=100, message="赛事名称长度不能超过100个字符")
    private String eventName;

    @Schema(description = "赛事类型：1-精选，2-普通")
    private Integer eventType;

    @Schema(description = "赛事描述")
    @Size(max=65535, message="赛事描述长度不能超过65535个字符")
    private String description;

    @Schema(description = "封面图片")
    @Size(max=500, message="封面图片长度不能超过500个字符")
    private String coverImage;

    @Schema(description = "开始时间")
    @NotNull(message = "开始时间不能为空")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime startTime;

    @Schema(description = "结束时间")
    @NotNull(message = "结束时间不能为空")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime endTime;

    @Schema(description = "报名开始时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime registrationStart;

    @Schema(description = "报名结束时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime registrationEnd;

    @Schema(description = "最大参与人数")
    private Integer maxParticipants;

    @Schema(description = "当前参与人数")
    private Integer currentParticipants;

    @Schema(description = "状态：1-报名中，2-进行中，3-已结束，4-已取消")
    private Integer status;

    @Schema(description = "主办方")
    @Size(max=100, message="主办方长度不能超过100个字符")
    private String organizer;

    @Schema(description = "活动地点")
    @Size(max=255, message="活动地点长度不能超过255个字符")
    private String location;

    @Schema(description = "路线数据")
    @Size(max=-1, message="路线数据长度不能超过-1个字符")
    private String routeData;

   


}
